package org.tp8.sampleapp.service.abs;

import java.io.Serializable;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;
import org.tp8.sampleapp.model.AbstractModel;
import org.tp8.sampleapp.persistence.repository.BaseRepository;
import org.tp8.sampleapp.service.BaseEntityService;

/**
 * The Class AbstractEntityService.
 * 
 * @param <K>
 *            the key type
 * @param <T>
 *            the generic type
 * @param <R>
 *            the generic type
 */
@Transactional(propagation = Propagation.REQUIRED)
@Service
public abstract class AbstractEntityService<K extends Serializable, T extends AbstractModel<K>, R extends BaseRepository<K, T>>
		extends AbstractService implements BaseEntityService<K, T> {

	/**
	 * Gets the repository.
	 * 
	 * @return the repository
	 */
	public abstract R getRepository();

}
